﻿<%@ Page Title="" Language="C#" MasterPageFile="~/layout/admin.Master" AutoEventWireup="true" CodeBehind="MenuList.aspx.cs" Inherits="SinhNhat.admin.menu.MenuList" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentMain" runat="server">

    
    


    <asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" 
        DataKeyNames="MenuID" DataSourceID="LinqDataSource1" Width="100%" 
        BackColor="White" BorderColor="#999999" BorderStyle="None" BorderWidth="1px" 
        CellPadding="3" GridLines="Vertical">
        <AlternatingRowStyle BackColor="#DCDCDC" />
        <Columns>
            <asp:CommandField ShowEditButton="True" />
            
            <asp:BoundField DataField="MenuText" HeaderText="MenuText" SortExpression="MenuText" />
            
            <asp:BoundField DataField="Url" HeaderText="Url" SortExpression="Url" /> 
            <asp:TemplateField HeaderText="Manage">
                <ItemTemplate>
                        <asp:HyperLink ID="EditLink" NavigateUrl='<%# Eval("MenuID","~/admin/menu/Menu.aspx?id={0}") %>' runat="server">
                            <asp:Image ID="EditImage" ImageUrl="/public/css/images/admin/edit.gif"  runat="server" />
                        </asp:HyperLink>

                        <asp:ImageButton ID="btnDelete" runat="server" CausesValidation="False" ImageUrl="/public/css/images/admin/delete.gif" 
                            CommandName="Delete" Text="Delete"
                            OnClientClick="return confirm('Are you sure you want to Delete this record ?')" />

                 </ItemTemplate>
            </asp:TemplateField>
        </Columns>
        <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
        <HeaderStyle BackColor="#000084" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
        <RowStyle BackColor="#EEEEEE" ForeColor="Black" />
        <SelectedRowStyle BackColor="#008A8C" Font-Bold="True" ForeColor="White" />
        <SortedAscendingCellStyle BackColor="#F1F1F1" />
        <SortedAscendingHeaderStyle BackColor="#0000A9" />
        <SortedDescendingCellStyle BackColor="#CAC9C9" />
        <SortedDescendingHeaderStyle BackColor="#000065" />
    </asp:GridView>

    <asp:LinqDataSource ID="LinqDataSource1" runat="server" 
        ContextTypeName="DAL.SinhNhatDBDataContext" 
        EnableDelete="True" EnableUpdate="True"
        EntityTypeName="" TableName="MENUs">
    </asp:LinqDataSource>

</asp:Content>
